<html>
<head><meta charset="utf-8"><title>why does lexical_region_resolve still exist? · t-compiler/help · Zulip Chat Archive</title></head>
<h2>Stream: <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/index.html">t-compiler/help</a></h2>
<h3>Topic: <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/why.20does.20lexical_region_resolve.20still.20exist.3F.html">why does lexical_region_resolve still exist?</a></h3>

<hr>

<base href="https://rust-lang.zulipchat.com">

<head><link href="https://rust-lang.github.io/zulip_archive/style.css" rel="stylesheet"></head>

<a name="216253044"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/why%20does%20lexical_region_resolve%20still%20exist%3F/near/216253044" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Gus Wynn <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/why.20does.20lexical_region_resolve.20still.20exist.3F.html#216253044">(Nov 10 2020 at 18:28)</a>:</h4>
<p>I am reading this: <a href="https://rustc-dev-guide.rust-lang.org/borrow_check/region_inference.html">https://rustc-dev-guide.rust-lang.org/borrow_check/region_inference.html</a> and <a href="https://github.com/rust-lang/rust/tree/master/compiler/rustc_infer/src/infer/lexical_region_resolve">https://github.com/rust-lang/rust/tree/master/compiler/rustc_infer/src/infer/lexical_region_resolve</a> and it says lexical region resolution is dead, but it seems to be the type of resolution that happens in <code>resolve_regions_and_report_errors</code>. is it just misnamed?</p>



<a name="216254083"></a>
<h4><a href="https://rust-lang.zulipchat.com#narrow/stream/182449-t-compiler/help/topic/why%20does%20lexical_region_resolve%20still%20exist%3F/near/216254083" class="zl"><img src="https://rust-lang.github.io/zulip_archive/assets/img/zulip.svg" alt="view this post on Zulip" style="width:20px;height:20px;"></a> Gus Wynn <a href="https://rust-lang.github.io/zulip_archive/stream/182449-t-compiler/help/topic/why.20does.20lexical_region_resolve.20still.20exist.3F.html#216254083">(Nov 10 2020 at 18:36)</a>:</h4>
<p>hmm <a href="https://rustc-dev-guide.rust-lang.org/type-inference.html?highlight=infer#extracting-region-constraints">https://rustc-dev-guide.rust-lang.org/type-inference.html?highlight=infer#extracting-region-constraints</a> mentions "To solve lexical region constraints, you invoke resolve_regions_and_report_errors. This "closes" the region constraint process and invokes the lexical_region_resolve code."</p>
<p>do we have a list of what things we just resolve lexically (and not with nll)? <a href="https://github.com/rust-lang/rust/pull/76765/files">https://github.com/rust-lang/rust/pull/76765/files</a> is interesting because its a lifetime error that fails after lexical resolution</p>



<hr><p>Last updated: Aug 07 2021 at 22:04 UTC</p>
</html>